Text Translation (preview:2025-10-01)

2025/10/15 • 3 new methods

GetSupportedLanguages (new)
Description Gets the set of languages currently supported by other operations of the Translator.
Reference Link ¶

⚼ Request

GET:  /languages
{
X-ClientTraceId: string ,
scope: string ,
Accept-Language: string ,
If-None-Match: string ,
api-version: string ,
}

⚐ Response (200)

{
$headers:
{
etag: string ,
x-requestid: string ,
}
,
$schema:
{
translation: object ,
transliteration: object ,
dictionary: object ,
}
,
}

⚐ Response (default)

{
$headers:
{
x-requestid: string ,
}
,
$schema:
{
error:
{
code: string ,
message: string ,
}
,
}
,
}
Translate (new)
Description Translate Text
Reference Link ¶

⚼ Request

POST:  /translate
{
X-ClientTraceId: string ,
api-version: string ,
body:
{
inputs:
[
{
text: string ,
script: string ,
language: string ,
textType: enum ,
targets:
[
{
language: string ,
script: string ,
profanityAction: enum ,
profanityMarker: enum ,
deploymentName: string ,
allowFallback: boolean ,
grade: string ,
tone: string ,
gender: string ,
adaptiveDatasetId: string ,
referenceTextPairs:
[
{
source: string ,
target: string ,
}
,
]
,
}
,
]
,
}
,
]
,
}
,
}

⚐ Response (200)

{
$headers:
{
x-requestid: string ,
x-metered-usage: integer ,
x-mt-system: string ,
}
,
$schema:
{
value:
[
{
detectedLanguage:
{
language: string ,
score: number ,
}
,
translations:
[
{
language: string ,
sourceCharacters: integer ,
instructionTokens: integer ,
sourceTokens: integer ,
responseTokens: integer ,
targetTokens: integer ,
text: string ,
}
,
]
,
}
,
]
,
}
,
}

⚐ Response (default)

{
$headers:
{
x-requestid: string ,
}
,
$schema:
{
error:
{
code: string ,
message: string ,
}
,
}
,
}
Transliterate (new)
Description Transliterate Text
Reference Link ¶

⚼ Request

POST:  /transliterate
{
X-ClientTraceId: string ,
language: string ,
fromScript: string ,
toScript: string ,
api-version: string ,
body:
{
inputs:
[
{
text: string ,
}
,
]
,
}
,
}

⚐ Response (200)

{
$headers:
{
x-requestid: string ,
}
,
$schema:
{
value:
[
{
text: string ,
script: string ,
}
,
]
,
}
,
}

⚐ Response (default)

{
$headers:
{
x-requestid: string ,
}
,
$schema:
{
error:
{
code: string ,
message: string ,
}
,
}
,
}